<%@ page contentType="text/html;charset=UTF-8"%>
<%@ taglib prefix="c" uri="http://java.sun.com/jsp/jstl/core"%>
<%@ taglib prefix="tags" tagdir="/WEB-INF/tags"%>
<c:set var="ctx" value="${pageContext.request.contextPath}" />
<!doctype html>
<html lang="en">

<head>
<!-- bootstrap -->
<%-- <link type="text/css" rel="stylesheet" href="${ctx}/static/styles/bootstrap/css/bootstrap.min.css">
<link type="text/css" rel="stylesheet" href="${ctx}/static/styles/bootstrap/css/bootstrap-responsive.min.css"> --%>
<link href="${ctx}/static/xform/styles/layout3.css" rel="stylesheet">
<script src="${ctx}/static/js/selectWin/userSelector.js" type="text/javascript"></script>
<title>编辑</title>
<script type="text/javascript">
	$(function() {
		$(".userSelector").click(function() {
			var $this = $(this);
			$.easyui.showGridSelector($.extend(window.userSelectOpts, {
				onEnter : function(val) {
					$this.prev().val("人员:" + val[0].trueName);
				}
			}));
		});
	});
</script>
</head>
<body>
	<div class="row-fluid">
		<!-- start of main -->
		<section id="m-main" class="span10" style="float: left; margin: 10px">
			<article class="m-widget">
				<header class="header">
					<h4 class="title">编辑</h4>
				</header>
				<div class="content content-inner">
					<form id="demoForm" method="post" action="${ctx}/bpm/confForm/form-confirmStartProcess.do" class="form-horizontal">
						<input id="demo_bpmProcessId" type="hidden" name="bpmProcessId" value="${bpmProcessId}">
						<input id="demo_businessKey" type="hidden" name="businessKey" value="${businessKey}">
						<input id="demo_status" type="hidden" name="status" value="taskConf">
						<c:if test="${taskDefinitions != null}">
							<table class="table table-border">
								<thead>
									<tr>
										<td>任务</td>
										<td>负责人</td>
									</tr>
								</thead>
								<tbody>
									<c:forEach items="${taskDefinitions}" var="item">
										<tr>
											<td><input type="hidden" name="taskDefinitionKeys" value="${item.key}">${item.nameExpression}</td>
											<td><input type="text" name="taskAssignees" value="${item.assigneeExpression}"> <a 
													class="userSelector easyui-linkbutton easyui-tooltip" data-options="plain: true, iconCls: 'icon-metro-search',content:'选取人员'"></a></td>
										</tr>
									</c:forEach>
								</tbody>
							</table>
						</c:if>
						<div class="control-group">
							<div class="controls">
								<button id="submitButton" type="submit" class="btn">保存</button>
								&nbsp;
								<button type="button" onclick="history.back();" class="btn">返回</button>
							</div>
						</div>
					</form>
				</div>
			</article>
		</section>
		<!-- end of main -->
	</div>
</body>
</html>
